package work.huangxin.share.mapper;

import org.apache.ibatis.annotations.Param;
import tk.mybatis.mapper.common.Mapper;
import work.huangxin.share.domain.other.UserMessage;

public interface UserMessageMapper extends Mapper<UserMessage> {


    UserMessage getUserMessage(@Param("userId") Integer userId);

    //将user_message表中的 user_allow 设置为1
    int updateUserAllowByUserId(@Param("userId") Integer userId);

    //将user_message表中的 user_allow 设置为 2
    int updateUserNotAllowByUserId(@Param("userId") Integer userId);

    //编辑用户信息
    int editUser(UserMessage userMessage);


    int getNewUserCount(@Param("firstDayDate") String firstDayDate, @Param("lastDayDate") String lastDayDate);

    Integer getTotalUser();
}